package com.matt.service;

import com.matt.commons.page.PagerQuery;
import com.matt.domain.LiveRoom;
import org.springframework.data.domain.Page;

import java.util.List;

/**
 * *******************************
 * Created by Ron.
 * form com.matt
 * on 2017/8/1
 * *******************************
 */
public interface LiveRoomService {

    List<LiveRoom> getRoomByArea(String areaId);

    List<LiveRoom> getActiveRoomByArea(String areaId);

    Page getActiveRoomByAreaPage(String areaId,PagerQuery pagerQuery);

    List<LiveRoom> getActiveRoomByAreaAndNoChoosen(String areaId, String teachAreaId);

    LiveRoom getByIdInArea(String roomId,String areaId);

    LiveRoom add(String url, String HDUrl, String thumbUrl, String yingshiId, String name,
                 Integer type, String areaId, String teachingAreaId,  Boolean isActive);

    LiveRoom modify(String roomId, String url, String HDUrl, String thumbUrl, String yingshiId,  String name,
                    Integer type, String areaId, String teachingAreaId,  Boolean isActive);

    LiveRoom delete(String areaId, String staffId, String liveRoomId);

    LiveRoom modifyName(String roomId, String name,List<String> time, String areaId);

    LiveRoom modifyStatus(String roomId, Boolean active, String areaId);

    List<LiveRoom> getRoomListPreviewIsNull();

    List<LiveRoom> getAllRoomList();

//    boolean updateThumbUrlByYinshiId(String yingShiId, String url);

    LiveRoom updateThumbUrlById(String areaId, String id, String url);

    String getAreaYinShiToken(String areaId);

    String getLiveRoomHLSAddress(LiveRoom liveRoom);

    void updateDate( String liveRoomId);

    void shutdownAllDeadCamera();

    Integer openLive(LiveRoom liveRoom);

    Integer openLive(String areaId, String liveRoomId);

    LiveRoom closeLive(String areaId, String liveRoomId) ;

    LiveRoom closeLive(LiveRoom liveRoom) ;
}
